Skip to content

Conversation

@hpohekar
Copy link
Collaborator

@hpohekar hpohekar commented Jun 19, 2024

Register unit without updating yaml file.

    >>> from ansys.units import register_unit
    >>> register_unit(unit="Q", composition="N m", factor=1)
    >>> ureg = UnitRegistry()
    >>> ureg.Q
    _name: Q
    _dimensions: {'MASS': 1.0, 'LENGTH': 2.0, 'TIME': -2.0}
    _composition: N m
    _factor: 1
    _si_units: kg m^2 s^-2
    _si_scaling_factor: 1.0
    _si_offset: 0.0

@github-actions github-actions bot added testing Anything related to tests enhancement New features or code improvements labels Jun 19, 2024
@hpohekar hpohekar changed the title feat: Register unit feat: Register unit without updating config files Nov 7, 2024
@pyansys-automation
Copy link
Collaborator

Hello @hpohekar!
This issue has been open for over a year and has had no updates in the past 8 months. If it is still relevant, please provide an update. Otherwise, consider closing it to help keep the issue tracker clean.

If this issue needs to remain open, please comment below with @pyansys-automation never close issue to prevent it from being automatically closed.

If you want this repository to be excluded from this automated maintenance process, please let us know by filling in the opt-out request form.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New features or code improvements testing Anything related to tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants